import { toSuccess, useRedis } from "@sker/core";
import { useData } from "@sker/runtime";
import * as helper from './kwaiHelper';
/**
 * 找包
 */
export default async () => {
    const body = helper.input.parse(useData())
    const userId = body.userId;
    if (!userId) throw new Error(`userId不能为空`)
    const data = await useRedis(0, async (r) => {
        return await helper.addRoomInfo(r, body)
    })
    return toSuccess(data)
}